updating oE create_directory
create_directory
include filesys.e namespace filesys public function create_directory(sequence name, integer mode = 448, integer mkparent = 1)
creates a new directory.
Parameters:
- name : a sequence, the name of the new directory to create
- mode : on Unix systems, permissions for the new directory. Default is 448 (all rights for owner, none for others).
- mkparent : If true (default) the parent directories are also created if needed.
Returns:
An integer, 0 on failure, 1 on success.
Comments:
mode is ignored on Windows platforms.
Example 1:
if not create_directory("the_new_folder") then crash("Filesystem problem - could not create the new folder") end if -- This example will also create "myapp/" and "myapp/interface/" -- if they don't exist. if not create_directory("myapp/interface/letters") then crash("Filesystem problem - could not create the new folder") end if -- This example will NOT create "myapp/" and "myapp/interface/" -- if they don't exist. if not create_directory("myapp/interface/letters",,0) then crash("Filesystem problem - could not create the new folder") end if
See Also:
Not Categorized, Please Help
|